#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Created by Zxc on 1/25/21 11:03 下午 .

import sys
from PIL import Image
# 请修改成你下载的chinese ocr （https://github.com/DayBreak-u/chineseocr_lite）项目的本地路径
sys.path.append("/Users/zxc/github/chineseocr_lite")
from model import OcrHandle
ocrhandle = OcrHandle()
if __name__ == '__main__':
    # 替换成你要ocr的image
    image = Image.open("img.png")
    result = ocrhandle.text_predict(image, 960)
    print(result)
